package com.kimi.abyss.rbac.api.feign.fallback;

import com.kimi.abyss.rbac.api.dto.UserInfo;
import com.kimi.abyss.rbac.api.feign.RemoteSysUserService;
import lombok.Setter;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import reactor.core.publisher.Mono;

/**
 * no-op
 *
 * @author kimi
 * @date 2021/7/19
 */
@Slf4j
@Component
public class RemoteSysUserServiceFallbackImpl implements RemoteSysUserService {

    @Setter
    private Throwable cause;

    @Override
    public Mono<UserInfo> getUserInfo(String username) {
        log.error("查询用户信息失败:{}", username, cause);
        return null;
    }
}
